package com.pig4cloud.pigx.contract.bo;

import com.pig4cloud.pigx.contract.entity.ContractOrder;
import com.pig4cloud.pigx.contract.entity.ContractPosition;
import com.pig4cloud.pigx.contract.mongo.entity.ContractSymbolMongo;
import lombok.Data;

import java.math.BigDecimal;
import java.time.LocalDateTime;
import java.util.List;

/**
 * 仓位强平BO
 *
 * @since 2022/9/3 20:59
 */
@Data
public class ContractPositionLiquidatorBO extends ContractPosition {
    /**
     * 币对信息
     */
    private ContractSymbolMongo symbol;
    /**
     * 当前时间
     */
    private LocalDateTime now;
    /**
     * 撤销的止盈止损idList
     */
    private List<Long> canceledStopOrderIdList;
    /**
     * 已撤销订单集合
     */
    private List<ContractOrder> canceledOrderList;
    /**
     * 拥有剩余金额
     */
    private Boolean hasRestAmount;
    /**
     * 订单
     */
    private ContractOrder order;

    /**
     * 平仓均价
     */
    private BigDecimal thisCloseAvgPrice;
    /**
     * 本次盈亏
     */
    private BigDecimal thisProfit;
    /**
     * 收益率
     */
    private BigDecimal thisProfitRate;
    /**
     * 本次订单面值
     */
    private BigDecimal thisOrderValue;
    /**
     * 本次手续费
     */
    private BigDecimal thisHandlingFee;
    /**
     * 本次强平清算费
     */
    private BigDecimal thisLiquidateFee;
    /**
     * 本次订单利润率
     */
    private BigDecimal thisOrderProfitRate;
}
